Physics-informed deep generative learning for quantitative assessment of the retina

Disruption of retinal vasculature is linked to various diseases, including diabetic retinopathy and macular degeneration, leading to vision loss. We present here a novel algorithmic approach that generates highly realistic digital models of human retinal blood vessels, based on established biophysical principles, including fully-connected arterial and venous trees with a single inlet and outlet. This approach, using physics-informed generative adversarial networks (PI-GAN), enables the segmentation and reconstruction of blood vessel networks with no human input and which out-performs human labelling. Segmentation of DRIVE and STARE retina photograph datasets provided near state-of-the-art vessel segmentation, with training on only a small (n = 100) simulated dataset. Our findings highlight the potential of PI-GAN for accurate retinal vasculature characterization, with implications for improving early disease detection, monitoring disease progression, and improving patient care.


Introduction
Disruption of retinal vasculature is associated with a range of diseases which can result in loss of vision, including diabetic retinopathy (DR) [1] and macular degeneration [2]. It is also increasingly recognized that retinal vasculature can indicate the presence of systemic pathology, such as vascular dementia [3] and cardiovascular disease [4]. Automated methods to characterize changes in retinal vasculature from clinical imaging data therefore offer substantial promise for high-throughput, early detection of disease [5,6], which is critically required to meet the increasing incidence of retinal disease, potentially alongside other vascular diseases, and their associated burden on healthcare systems [7,8].
Much attention has been placed on supervised deep learning in this regard, where deep neural networks are trained to categorise images according to diagnosis or identify the location of features of interest [9]. Supervised learning, particularly with U-net architectures [10], first rose to prominence in retinal image analysis for segmenting retinal layers in optical coherence tomography (OCT) data [11], alongside blood vessels segmentation in retinal photographs [12,13]. A significant limitation to this type of approach is the lack of high-quality, manually-labelled image data in sufficient quantities to enable accurate and generalisable predictions to be made [14,15]. This problem is particularly acute for the detection of blood vessels, in which manual labelling is highly time-consuming, generally limited to two-dimensional (2D) projections, confined to larger vessels only, and generally does not distinguish between arteries and veins [16,17]. Retinal blood vessel networks, featuring arterial and venous trees connected by a capillary bed, and special treatment of macular and optic disc features, were simulated using space filling growth algorithms based on Murray's law. Blood flow and fluorescein delivery were simulated in synthetic vascular networks, using onedimensional Poiseuille flow. By combining this with cycle-consistent, physics-informed deep generative learning, vessel simulations were converted into synthetic medical image data (fundus photography, Optical coherence tomography angiography (OCT-A) and fluorescein angiography), and the same trained networks used to detect blood vessels in clinical images.

Procedural modelling of retinal vasculature
Retinal vascular networks were simulated in multiple, linked steps, using a combination of algorithms that draw on the known geometry and biophysics of retinal vasculature. In total, our procedural model of retinal vasculature contained 26 parameters (Supplemental Table 1), each of which were randomly sampled to simulate the broad range of retinal geometries occurring in the population (Figure 2a-c) [24].
Networks were seeded using a Lindenmayer-system (L-system) [25], in which initial central retinal artery and vein segments were positioned at the location of an optic disc and iteratively branched within a plane. The first arterial and venous segment radii were 135 ± 15 µm and 151 ± 15 µm, respectively [26]. Branching was performed asymmetrically to create characteristically large vessels surrounding the macula, with smaller branches reaching towards the periphery, as observed in retinal images [26].
Seeding L-systems were then grown to the edge of the retina using a variant of constrained constructive optimisation (CCO) [27][28][29][30][31]. This step transformed L-system networks into realistic, space-filling networks with geometries defined by Murrays law [18] (exponent of 2.4 ± 0.11 [32]), whilst retaining the realistic macroscopic branching geometry imposed by the L-system seeding (Figure 2d-f). A final growth step was incorporated to create the characteristic branching pattern of the macula, with radial alignment of arterioles and venules, greater relative vascular flow density (between 1.5 and 2.0 times the perfusion fraction) and a central avascular fovea.
Following growth, we augmented vessels with sinusoidal displacements to replicate the tortuous vasculature commonly observed in human retinas, with a greater displacement imposed on veins. A continuous capillary bed was generated using either 1) a 2D Voronoi algorithm that arterial and venous endpoints were connected to [33] or 2) a 2D space colonization algorithm [34]. Following simulation within a 2D plane, vessels were projected onto a hemispherical mesh (radius 23 -25 mm) featuring macula and optic disc structures generated using a mixed Gaussian profile [35] (Figure 2, Supplemental Figure 1).

Comparison of synthetic networks with real-world networks
Our set of retinal network growth algorithms is designed to provide an authentic replication of real retinal vasculature, by following established biophysical principles. To quantitatively evaluate the accuracy of these synthetic networks, we manually labelled all visible blood vessels in 19 optical coherence tomography angiography (OCT-A) image datasets, using inhouse software. This included differentiating arteries and veins (A-V) in a subset of images (n=5), using retinal photographs as a reference for determining A-V status. Vessel branching angle, inter-branch length, tortuosity, and radius were measured in three regions: the macula, the vessels surrounding the optic disc, and the periphery. The macula was defined as a 5.5 mm diameter circular area centred on the fovea, based on measurements referenced in Remington and Goodwin [36]. The vessels surrounding the optic disc were labelled as a 3.6mm diameter centred at the optic disc, due to mean vertical and horizontal diameters of the optic disc reported as 1.88 and 1.77mm respectively [37]. Vessels outside these regions were defined as 'peripheral'. 100 synthetic retinal networks were initially created, with parameter values randomly drawn from the ranges shown in Supplemental Table 1.
According to ANOVA analysis, all geometric parameters associated with synthetic blood vessel networks did not reach the level of statistical significance compared to those measured in normal controls using manual segmentation of OCT-A images (branching angle, p = 0.82; vessel length, p = 0.17; vessel tortuosity, p = 0.095; vessel network volume, p = 0.061; vessel diameter, p = 0.59) (Figure 3, Supplemental Table 2).

Figure 3.
Comparison of retinal vascular geometry distributions visualised with bar plots between manually segmented networks from OCT-A data (normal volunteers not ascertained for disease status) and simulated networks. a) Branching angle, b) vessel length (µm), c) vessel tortuosity, d) vessel network volume and e) vessel diameter (µm), in three regions: macula (5.5mm diameter circular area centred on the fovea [36]), optic disc (3.6mm diameter area centred on the optic disc centre [37]), and periphery (all vessels outside those regions).

Simulating retinal blood flow and validation using fluorescein angiography
We have previously developed a mathematical framework for simulating blood flow in three dimensional vascular networks, which uses one-dimensional Poiseuille flow [38]. Our simulated retinal networks are ideally suited for this framework, having just one arterial input and one venous outlet meaning that pressure boundary conditions can be easily specified. Setting arterial pressure by sampling from a normal distribution parameterised by mean = 54.3 mmHg, s.d. = 14.0 mmHg [39] and similarly for venous pressure with mean = 20.0mmHg and s.d. = 10.0 mmHg [39] gave an average total retinal flow prediction of 34.4 ± 1.8 µL/min, which is slightly lower, but still in good agreement with reports in the literature from healthy retinas (for example, 45.6 ± 3.8 µL/min [39] 44 ± 13 µL/min [40] 50.7 µL/min [40] (Figure 4a,b).
To further evaluate these flow results, we next performed a simulation of retinal fluorescein delivery. Fluorescein angiography is used in ophthalmology for diagnosis of macular edema, macular degeneration, RVO, DR, and other diseases [41,42]. Fluorescein is injected as a bolus into the median cubital vein, and 10-15 seconds later appears in the choroidal vasculature at the rear of the eye [43]. Within 2 seconds of this, fluorescein appears in the anterior arteries and arterioles, and a further two seconds later by partial filling of venules and veins, followed by total filling and recirculation.
We simulated the systemic pharmacokinetics of fluorescein using literature data (Supplemental Figure 2), with the passage of fluorescein modelled as two displaced Gaussian functions to model the first and second passes, and an exponential washout term corresponding to systemic extraction. This time course was propagated through our synthetic retinal networks by partitioning by flow at branch points and delaying according to cumulative velocities. The delay between arterial and venous filling with fluorescein, across 1000 simulation runs was 7.3 ± 0.7 s, which is in keeping with timings described in clinical data [43]. Visual inspection of fluorescein delivery also revealed a good accordance with clinical delivery profiles (Figure 4c

Simulating retinal pathology
Given the physiologically-realistic results provided by our flow models, we next sought to perturb our simulated networks to examine the effect of pathological changes. As a first demonstration, we simulated the effect of RVO. A random location of artery-vein crossover on a large retinal vein was reduced in diameter by 80%. Blood flow within the network was recalculated, revealing a large region of hypoperfusion, as expected. This strongly reflected the presentation of RVO found in clinical fluorescein angiography data ( Figure 5) and induced a regional reduction in blood flow of 9.8 µL/min in the vessels immediately downstream of the occlusion.
Next, we constructed a simple model of DR [44][45][46], in which arterioles with a radius less than 35 µm were randomly selected and occluded, and the resultant change in network flow calculated. All vessels that become non-perfused, either up-or downstream of the occluded vessel, were removed from the network, creating regions of ischemia, with occasional surviving vessels passing through (Figure 5c  Generating synthetic clinical ophthalmology data with deep learning Our next challenge was to use deep learning to define a mapping between our biophysical vascular model and clinical ophthalmology data (and vice versa). For this we used cycleconsistent generative adversarial networks that enabled the translation of image texture and style between image domains [47] We undertook this for three clinical imaging modalities: OCT-A, retinal photographs and fluorescein angiography We embedded our synthetic retinas in three-dimensional grids with axial and lateral resolutions of 6.3 µm and 21 µm, respectively, to match our clinical OCT-A data. We then trained three cycle-consistent GANs on these synthetic retinas, with each GAN mapping the conversion between the synthetic images and a different imaging modality. 590 retinal photographs, 43 OCT-A en-face images and 570 fluorescein angiography images were used in training for this purpose. PI-GAN enabled the geometry of source images (simulations) to be translated into a target style (retinal photographs, OCT-A, etc). As can be seen in Figure 6a, following 400 training epochs, the pattern of synthetic vasculature was realistically transferred into the style of each target image. The Frechet Inception Distance (FID) was 6.95 for retinal photographs, 5.17 for fluorescein angiographs and 3.06 for OCT-A en-face images, indicating a small distance between feature vectors for real and fake images.
This process generated authentic-looking retinal image data with matched, fully specified ground truth blood vessels. However, cycle consistency also allows the reverse operation: to generate simulation data from clinical images (Figure 6b). This enabled blood vessel networks to be segmented from OCT-A images and compared with manual segmentations of the same data (Figure 7). Visual inspection of PI-GAN segmentations revealed many more small 'elusive' vessels [48] than represented within our manually-segmented images, arguably providing superior segmentation accuracy than the manual 'gold standard'. Accordingly, the mean Dice score for OCT-A images was low (mean 0.35, s.d. 0.12 (2.s.f)), but the sensitivity (the percentage of pixels labelled as vessel in the manual segmentation that were also identified as vessel by PI-GAN) was high (87.1% (s.d. 1.20)), showing that PI-GAN is able to accurately label almost all of the vessels identified by human operators (Figure 7g-j).
To further investigate this result, we evaluated PI-GAN on two publicly available retinal photograph data sets with corresponding manual segmentations (STARE and DRIVE). Contrasting the widefield (130 degree and 200 degree montage) images analysed here, these datasets were acquired with a smaller 45 degree FOV, and are widely used in benchmarking vessel segmentation. Again, Dice scores comparing manual and PI-GAN segmentations were low but, as shown in Figure 7k-m and Supplemental Figure 5, PI-GAN was able to detect most of the manually-segmented vessels, but also many smaller, elusive vessels. Mean DICE score between DRIVE manually segmented data and segmentations generated using PI-GAN was 0.56 (s.d. 0.013) (2.d.p) and for STARE it was 0.64 (s.d. 0.19) (2.d.p). These results call into question how appropriate manual segmentation is as a gold standard in this setting, visual inspection suggests these additional small vessels are indeed physiological and were simply missed by manual segmentation.
These results demonstrate the key ability of physics-informed simulations with deep learning to autonomously segment blood vessels within a range of ophthalmology imaging modalities, without the need for any manually-labelled training data.

Discussion
Methods that enable the quantitative assessment of retinal vasculature from clinical ophthalmology images are critically needed for evaluating the progression of diseases such as DR, and also to support research into the influence of systemic diseases such as cardiovascular disease and vascular dementia [3,4]. In this regard, deep learning is rapidly transforming ophthalmology, but requires access to large volumes of well-curated data before it can be implemented with confidence in the clinic [50,51]. In the assessment of vasculature, manual image labelling constitutes a considerable bottleneck in terms of time, expense and labelling accuracy [52], as manual segmentation of a single 2D retinal image can take multiple hours [53]. Inter and intra grader variability can also be significant within the segmentation process [54,55]. Most segmentation studies have been conducted in 2D retinal fundus photographs using public datasets [14,56,57]. Approaches that can relieve this bottleneck are urgently needed to enable the robust translation of deep learning into the clinic.
To date, supervised deep learning approaches have yielded impressive results in 2D vessel segmentation relative to manual segmentation, although tend to favour precision over recall [5], resulting in an under-segmentation of faint vessels, underestimation of the width of thicker vessels and some 'elusive' vessels being missed [48]. This is problematic for diagnostic interpretation, because many biomarkers (such as artery-vein (AV) ratio, branching angles, number of bifurcations, fractal dimension and tortuosity) need precise measurements of individual vessels.
To address these challenges, we have presented here a physics-informed, generative approach that combines biophysical simulation with deep generative learning. A useful outcome of this approach is the ability to automatically segment vascular data from clinical evaluation images, without any need for manual segmentation. Specifically, we created a linked set of algorithms that draw on established principles in biophysics to simulate fully-connected retinal vasculature, in a three-dimensional domain, with special treatment for optic disc and macular regions. The full connectivity of our models, with separate arterial and venous trees, enables realistic blood flow and delivery simulations (for example, as we show in fluorescein angiography). We demonstrated that our synthetic vascular networks are highly concordant with real retinal vasculature metrics, with network statistics matching those from manual segmentations, in three regions: the optic disc, macula and periphery.
This close accordance between simulation and real-world geometries is key to its ability to segment blood vessels from ophthalmology images. Cycle-consistent deep generative learning allowed us to create realistic fundus photograph, OCT-A and FA images that inherently maintained feature geometry through the translation from simulation to clinical image domains. The resultant data are inherently paired, and so could provide data to augment conventional supervised learning approaches. However, cycle-consistency also facilitates the reverse translation, from clinical image domains back into the simulation domain, allowing the automated segmentation of blood vessels without human-labelled data. Comparing segmentation performance against manual segmentations revealed a much greater ability to label small vessels, and with excellent overlap with larger manually-segmented vessels. However, overall performance assessed via DICE score showed a relatively low accordance, due in part to the greater ability of the PI-GAN approach to detect small blood vessels, but also false-positives in both human-labelled and PI-GAN-labelled vessels. In regard to the latter, there are cases where GANs can 'hallucinate' features in images [58].
To date, supervised deep learning approaches have yielded impressive results in 2D vessel segmentation relative to manual segmentation, although tend to favour precision over recall [5], resulting in an under-segmentation of faint vessels, underestimation of the width of thicker vessels and some 'elusive' vessels being missed [48]. This is problematic for diagnostic interpretation, because many biomarkers (such as artery-vein (AV) ratio, branching angles, number of bifurcations, fractal dimension and tortuosity) need precise measurements of individual vessels. GANs incorporating cycle-consistency have previously been used for medical imaging domain machine learning tasks such as chest MRI to X-ray CT transformation [20], PET image denoising [21], and artefact reduction in fundus photography [22]. Likewise Menten et al used the space colonisation algorithm to generate macular blood vessel images, which they coupled with deep learning [23].
Our approach builds on this by incorporating biophysically-informed models of flow within fullyconnected artery and venous networks that extend across the entire retina, and our use of it to inform cycle-consistent deep generative learning. These developments allow application in larger field of view images (e.g. wide-field fundus photography), and also enable a large range of future applications, including flow modelling and oxygen delivery [59]. Moreover, given our ability to model arterial and venous trees, there is potential for independent segmentation of both vascular supplies.
These biophysical simulations also aimed to capture the wide range of variation found in real retinal networks, by varying the 26 simulation parameters across their reported physiological range. A further advantage of developing flow models into our biophysical framework was the ability to simulate pathology, such as the progression of DR and RVO. Many other pathologies could be simulated in follow-on studies, including changes in retinal vessel diameters associated with factors such as aging or hypertension. For example, Wong and colleagues reported retinal arteriolar diameters to decrease by approximately 2.1 µm for each decade increase in age, and by 4.4 µm for each 10 mmHg increase in arterial blood pressure [60]. Performing disease-specific deep generative learning runs will enable us to further refine our segmentation approaches and begin to characterise pathology.
Accordingly, there is also potential to use clinical data to further improve our biophysical simulations, enabling more accurate modelling of retinal physiology (and disease) and the ability to develop interpretable AI systems. The results of several recent studies using deep learning suggest that that retinal vasculature can provide a window into many systemic diseases (including dementia [3], kidney disease [61] and cardiovascular disease [4]), but cannot easily explain the structural basis of these associations. A PI-GAN framework is inherently coupled to biophysical laws, and so could help determine their origins or underpinning mechanistic processes. Additional challenges for segmentation are artery-vein classification [62] and establishing connectivity of the vessels [63], which, having a well-defined ground truth data set from simulations, could be realised through PI-GAN.
Overall our results demonstrate the potential of biophysical models of the retina, which can be interrogated to understand how physiological perturbations (such as disease) effect vascular function. Further work could explore regional variability in blood flow, with the temporal side exhibiting greater flow than the nasal side in both retinal venules and arteries, which may be related to retinal ganglion cell numbers [64]. Additionally, the model could be used in predicting inhibitors of angiogenesis, such as VEGF inhibitor Bevacizumab. Incorporating this model into a larger-scale retinal model (including the choroidal supply) would enable complete simulation of the retinal supply. The ability to then apply these simulation results for the interpretation of clinical images, via physics-informed generative learning, is a significant step forward.
Lindenmeyer system seeding Firstly, seeding networks following approximate retinal vascular branching geometry were constructed, starting with a putative central retinal artery and retinal vein positioned at the centre of the optic disc. The diameters of the retinal artery and vein were 135 ± 15 μm and 151 ± 15 μm, respectively [26], oriented parallel to the optic nerve (defined as the z-direction). Two branches were added to the end of each of these segments, oriented in the x-y plane, and one directed above and the other below the retinal midline. Subsequent branching of these vessels was performed stochastically, with segment lengths between bifurcations set as a fixed fraction of vessel diameter (18 ± 3) and bifurcation vessel diameters set according to: cos 0 = (1 + + ) -/+ + 1 − -2(1 + + ) 0/+

[2]
Normally-distributed noise was added to branching angle values, with a standard deviation of 5°. Vessel bifurcation angles were assigned such that the larger vessel oriented towards the macula to create putative major vessels oriented around the macula. Fifth-order bifurcations were added to the network, or until vessels breached the edge of the retina domain. Supplemental Figure 1a shows an example of an L-system seeding network.

Major vessel growth
Seed vessel networks were used as input into a multi-scale growth algorithm for the creation of hierarchical vasculature. First, seed networks were amended to provide a uniform distribution of leaf nodes (terminating arteriole and venuole nodes created prior to construction of capillary networks at a later stage) throughout the circular domain, using Accelerated Constrained Constructive Optimisation [31], using a leaf node spacing of 3 mm. Multiscale, two-dimensional lattices were defined (stride lengths ranging from 3000 to 150 µm, with five iterations linearly spaced within that range) and used to grow vessel networks by progressively adding vessels into unoccupied lattice sites from neighbouring occupied sites, choosing the candidate vessel which minimised the expected change in network cost (see below), and progressively reducing the length scale when no more progress could be made. After the initial growth stage, all existing leaf nodes were removed [65]. At all stages of the major vessel growth the macula region was kept free of vessels by removing vessels which intersected it, forcing flow to divert around it.
As retinal vasculature is positioned in front of the retina itself, we optimised networks to minimise the area of the retina occluded by vessels, according to a cost function based on Murray's law: ( , , ) = 7 9 : 9 < 9∈> with ρ=1 and λ=1, and where B is the set of vessel segments in the network, with length l and radius r. After each growth step the network geometry was optimised by moving vessel nodes, and highly asymmetric bifurcations were trimmed for regrowth [31] using the thresholds from [30] to account for the high asymmetry of optimal networks [30]. After growth at each length scale was terminated, the networks were optimised topologically by allowing asymmetric bifurcations to move their low-flow side downstream and branches which were short compared to their expected length under the West, Brown and Enquist model [66] to be treated as a single higher-order split for regrouping using a method similar to [67]. Due to the two-dimensional nature of the networks, network self-intersections were tested for using the approach of [31] however, rather than resolving the intersections by making excursions around the contact site we rewire the vessels to prevent future iterations from recreating the same intersection.
Unlike the implementation of [31], leaf nodes were allowed to move from their nominal location up to a specified "pinning distance", given as a fraction of the leaf spacing. Existing vessels could be specified as frozen, in which case the optimiser did not touch them. This approach was used to perturb the optimal root vessel structure with artificial tortuosity, strip away the downstream branches and regrow the downstream vessels, repeating this down the tree structure.

Macula growth
Vessels supplying the macula have a characteristic radial structure, motivating the development of a particular approach to enforce this structure. This uses the same lattice site invasion approach between the macula outer radius and the fovea (which is kept vessel-free), but with the stride set low enough that the majority of the growth arises from spreading over many iterations at the same length scale rather than hierarchical refinement. The macula has a configurable flow rate density compared to the rest of the retina, ranging from 1.5 to 2.0 and leaf nodes are offset by uniformly sampling an offset in a disc around the nominal position to ensure that vessels did not align along the lattice sites. The macula vessels were prevented from doubling back on themselves by setting a hard limit on the vessel angle, preventing obviously non-physiological structures from arising whilst still allowing the radial pattern to develop. After all leaf nodes are created, a sparsity factor is specified and each leaf node removed with this probability, then the remaining vessels are geometrically optimised.

Network overpass and interleaving
In the final stage, the arterial and venous networks have their collisions resolved using the method of [31], creating out-of-plane excursions around contact sites between the networks. To enable further micro-scale network growth techniques to create an interdigitated structure, we remove the low-flow side of all arterio-venous intersections with a radius below a critical value (5 um), leaving surviving vessel geometry untouched. Interdigitations were then created using a Space Colonisation implementation [68], interspersed with geometric optimisation.

Vessel tortuosity
The multi-scale growth algorithm creates relatively straight paths between branching points, and to simulate tortuous retinal vessels, particularly in veins, sinusoidal displacements were overlaid. Two oscillations were superimposed according to: @ ( , ) = ( , ) + C sin F C ( ) + C I + % sin F % ( ) + % I [3] where d(x,r) is the path taken by a vessel with radius r, and d'(x,r) is the modulated path. The amplitude of displacements, a0+a1 ranged from r to 3.5r for arteries and r to 7.5r for veins, with a low frequency period (τ0, ranging from 15r to 25r) and a high frequency period (τ1, ranging from 30r to 50r). The phase of the modulations, φ0 and φ1, enabled modulations to be matched between vessel bifurcations.

Simulating vascular flow and fluorescein delivery
Blood flow in retinal networks were simulated using our REANIMATE platform [38], which uses a connectivity-based formalism to optimise Poiseuille flow in tree-like spatial graphs. As anterior retinal vasculature features a single arterial inlet and venous outlet, the system requires only one pressure boundary condition (the difference between arterial and venous inlet pressures), which was fixed at 56.2 and 20 mmHg, respectively.
Time-dependent delivery of contrast agent (e.g. fluorescein) was simulated as described in d'Esposito et al [38]. Briefly, a bolus of fluorescein was simulated according to ( ) = % % ( ; % , % ) + 0 0 ( ; 0 , 0 ) + C Q(RQR S ) [4] where C(t) is the concentration of fluorescein as a function of time t. The first two terms, Gaussian functions, represent the first and second pass of the bolus and the third term, an exponential decay, represents the washout phase [69] The width of the first and second pass were σ1 = 10 s and σ2 = 25 s, respectively, and the decay rate of the washout phase, β, was 0.043 /minute. T1, t2 and τ are the time to peak for the first pass, second pass and washout phases, and were set at 0.171, 0.364 and 0.482 minutes, respectively [69]. S1, s2 and α were fixed at 0.833, 0.336 and 1.064 (dimensionless units). Peak concentration was normalised to unity at the inlet to the retinal artery and the time course in each connected vessel segment was time-shifted according to the velocity of blood in each vessel and scaled according to the ratio of flow in the parent and child vessels at bifurcation points.

Image datasets
This study was carried out in accordance with the Declaration of Helsinki [70].

Manual labelling of clinical data
Manually labelled data was generated using a custom-built Python package enabling tracing of vasculature in 3D. The process involved placing user defining control points on the 2D image indicating where in a slab the vessel is located via maximum intensity projection. The z-height of the vessel was then fixed by identifying the height of the highest signal intensity voxel, which was manually constrained to exclude the choroid or RPE. The radius of each vessel was automatically calculated by setting a user-defined signal intensity threshold. Review of segmented structures was performed in 3D panel to assess and ensure labelling quality. In images with pathological blood vessels such as DR the abnormal vasculature or areas of neoangiogenesis were traced in the same manner. Vessel information (vessel coordinates, edge connectivity, number of edge points, edge point coordinates, radii, and vessel type) was exported and stored in Amira spatial graph format (ThermoFisher Scientific, Waltham, Massachussetts USA). Retinal regions were labelled. The macula was defined as a 5.5 mm diameter circular area centred on the fovea. The vessels surrounding the optic disc were labelled as a 3.6 mm diameter centred at the optic disc. Vessels outside these regions were defined as 'peripheral'.

Deep generative learning
Image-to-image translation was performed using cycle-consistent generative adversarial networks [22]. This algorithm enables automated unsupervised training with unpaired samples, learning a bi-directional mapping function between two different domains with deep generative adversarial networks. It utilises cycle consistency, where the reconstructed image obtained by a cycle adaptation is expected to be identical to the original image for both generative networks. Cycle-consistent GANs are composed of two main deep neural network blocks which are trained simultaneously: an image generator (generator) and an adversarial network (discriminator). There is a loss (G loss) to make a synthesised image from domain A closer to a real image from domain B, and a loss (D loss) to distinguish the synthesised image from domain A from a real image from A. There are also losses facilitating the conversion in the opposite direction (G loss making synthesised image from domain B closer to domain A, and D loss to distinguish synthesised and real domain B images. Additionally, cycle loss is the difference between the input image and the double-synthesised image and identity loss is the difference between output and input images. A train/validation/test split of 75%/5%/20% was used. All PI-GANtraining and evaluation was performed using a single NVIDIA Titan RTX GPU.
We iteratively trained a switchable PI-GAN algorithm with 500 epochs. All networks were trained using the optimizer ADAM solver [35] with β1 = 0.5, β2 = 0.999. The learning rate for the first 100 epochs was 2*10 -4 , and then linearly decayed to 2*10 -6 . Images were pre-processed with crop size 256 pixels. The minibatch size was 1. The loss weights λ were set as 10. The model was trained on NVIDIA TITAN RTX in Pytorch v1.9.1.

Statistical evaluation of synthetic vessel networks
Vessel metrics of vessel branching angle, length, tortuosity, network volume and diameter were calculated. Analysis of variance (ANOVA) was used to assess differences in these metrics by retina region (optic disc, macula, and periphery) and by status (healthy control and simulated network) ( Table 1) with eye (right OD/ left OS), participant sex, and scan pattern used as covariates.

Evaluation metrics
Frechet inception distance GAN output was evaluated using the Fréchet Inception Distance (FID), which evaluates model quality by calculating the distance between feature vectors for real and generated images. FID compares the distribution of generated images with distribution of real images that were used to train the generator. Lower FID scores indicate more similarity between two groups. The FID score is calculated by first loading a pre-trained Inception v3 model. The output layer of the model is removed and the output is taken as the activations from the last pooling layer, a global spatial pooling layer.
Three FID scores were calculated: real simulation images (domain A) versus manually segmented vasculature clinical images; real retinal photographs (domain B) versus PI-GAN generated retinal photographs; real OCT-A images (domain C) versus PI-GAN generated OCT-A images; real fluorescein angiography (domain D) versus PI-GAN generated OCT-A images.

Dice score
Dice scores were additionally calculated. This is a commonly used performance statistic for evaluating the similarity of two samples. For a ground truth segmentation label L and associated prediction P, we measure the binary Dice score D: ( , ) = 2| ∩ | | | + | | [5]